import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { TabsPage } from './tabs.page';

const routes: Routes = [
  {
    path: 'tabs',
    component: TabsPage,
    children: [
      {
        path: 'dongtai',
        loadChildren: () => import('../dongtai/dongtai.module').then( m => m.DongtaiPageModule)
      },
      {
        path: 'shiwu',
        loadChildren: () => import('../shiwu/shiwu.module').then( m => m.ShiwuPageModule)
      },
      {
        path: 'changshi',
        loadChildren: () => import('../changshi/changshi.module').then( m => m.ChangshiPageModule)
      },
      {
        path: 'person',
        loadChildren: () => import('../person/person.module').then( m => m.PersonPageModule)
      },
      {
        path: '',
        redirectTo: '/tabs/dongtai',
        pathMatch: 'full'
      }
    ]
  },
  {
    path: '',
    redirectTo: '/tabs/dongtai',
    pathMatch: 'full'
  }
];

@NgModule({
  imports: [RouterModule.forChild(routes)],
})
export class TabsPageRoutingModule {}
